<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <title>首页</title>
    <meta http-equiv="X-UA-Compatible" content="IE=edge">
    <meta content="width=device-width,initial-scale=1.0,maximum-scale=1.0,user-scalable=0" name="viewport"/>
    <meta content="yes" name="apple-mobile-web-app-capable"/>
    <meta content="black" name="apple-mobile-web-app-status-bar-style"/>
    <meta content="telephone=no" name="format-detection"/>
    <link rel="stylesheet" href="statics/css/font-awesome.min.css">
    <link rel="stylesheet" href="statics/css/style.css">
    <link rel="stylesheet" href="statics/css/login.css">
    <link rel="stylesheet" href="statics/css/main.css">
    <link rel="stylesheet" href="statics/css/iview.css">
    <!-- HTML5 Shim and Respond.js IE8 support of HTML5 elements and media queries -->
    <!-- WARNING: Respond.js doesn't work if you view the page via file:// -->
    <!--[if lt IE 9]>
    <script src="statics/libs/html5shiv.min.js"></script>
    <script src="statics/libs/respond.min.js"></script>
    <![endif]-->
    <link href="statics/css/wxIndex.css" rel="stylesheet" type="text/css"/>
    <script>
        var _hmt = _hmt || [];
        (function () {
            var hm = document.createElement("script");
            hm.src = "https://hm.baidu.com/hm.js?4656e49e8efa9f2ad6868ea26fb8984c";
            var s = document.getElementsByTagName("script")[0];
            s.parentNode.insertBefore(hm, s);
        })();
    </script>
</head>
<body>
<div id="loginBox">
    <section class="jq22-flexView">
        <section class="jq22-scrollView">
            <div class="jq22-take-head">
                <div class="jq22-flex jq22-flex-one">
                    <div class="jq22-take-user">
                        <img src="statics/img/user.png" alt="">
                    </div>
                    <div class="jq22-flex-box">
                        <h2 v-cloak>{{user.username}}</h2>
                        <span v-cloak>
						<i class="icon icon-phone"></i>{{user.mobile}}
					</span>
                    </div>
                </div>
                <div class="jq22-flex jq22-flex-two">
                    <div class="jq22-flex-box">
                        <h3>修改个人信息</h3>
                    </div>
                    <div class="jq22-go-button">
                        <button @click="updateSysUser">修改</button>
                    </div>
                </div>
                <img src="statics/img/head.png" alt="">
            </div>
            <div class="jq22-take-item">
                <div class="jq22-flex" style="padding-bottom:0">
                    <div class="jq22-flex-box">
                        <h1>同城配送订单</h1>
                    </div>
                    <div class="jq22-arrow" @click="getGoodTong(5)">
                        <span>查看全部订单</span>
                    </div>
                </div>
                <div class="jq22-palace">
                    <a href="javascript:;" class="jq22-palace-grid" @click="getGoodTong(0)">
                        <div class="jq22-palace-grid-icon">
                            <img src="statics/img/nav-002.png" alt="">
                        </div>
                        <div class="jq22-palace-grid-text">
                            <h2>未配送</h2>
                        </div>
                    </a>
                    <a href="javascript:;" class="jq22-palace-grid" @click="getGoodTong(1)">
                        <div class="jq22-palace-grid-icon">
                            <img src="statics/img/nav-003.png" alt="">
                        </div>
                        <div class="jq22-palace-grid-text">
                            <h2>配送中</h2>
                        </div>
                    </a>
                    <a href="javascript:;" class="jq22-palace-grid" @click="getGoodTong(2)">
                        <div class="jq22-palace-grid-icon">
                            <img src="statics/img/nav-004.png" alt="">
                        </div>
                        <div class="jq22-palace-grid-text">
                            <h2>已配送</h2>
                        </div>
                    </a>
                    <a href="javascript:;" class="jq22-palace-grid" @click="getGoodTong(3)">
                        <div class="jq22-palace-grid-icon">
                            <img src="statics/img/nav-004.png" alt="">
                        </div>
                        <div class="jq22-palace-grid-text">
                            <h2>已取消</h2>
                        </div>
                    </a>
                </div>
            </div>


            <div class="jq22-take-item">
                <div class="jq22-flex" style="padding-bottom:0">
                    <div class="jq22-flex-box">
                        <h1>物流派送订单</h1>
                    </div>
                    <div class="jq22-arrow" @click="getGoodWu(5)">
                        <span>查看全部订单</span>
                    </div>
                </div>
                <div class="jq22-palace">
                    <a href="javascript:;" class="jq22-palace-grid" @click="getGoodWu(0)">
                        <div class="jq22-palace-grid-icon">
                            <img src="statics/img/nav-001.png" alt="">
                        </div>
                        <div class="jq22-palace-grid-text">
                            <h2>待支付</h2>
                        </div>
                    </a>
                    <a href="javascript:;" class="jq22-palace-grid" @click="getGoodWu(1)">
                        <div class="jq22-palace-grid-icon">
                            <img src="statics/img/nav-002.png" alt="">
                        </div>
                        <div class="jq22-palace-grid-text">
                            <h2>待发货</h2>
                        </div>
                    </a>
                    <a href="javascript:;" class="jq22-palace-grid" @click="getGoodWu(2)">
                        <div class="jq22-palace-grid-icon">
                            <img src="statics/img/nav-003.png" alt="">
                        </div>
                        <div class="jq22-palace-grid-text">
                            <h2>待收货</h2>
                        </div>
                    </a>
                    <a href="javascript:;" class="jq22-palace-grid" @click="getGoodWu(3)">
                        <div class="jq22-palace-grid-icon">
                            <img src="statics/img/nav-004.png" alt="">
                        </div>
                        <div class="jq22-palace-grid-text">
                            <h2>售后</h2>
                        </div>
                    </a>
                </div>
            </div>


            <div class="jq22-take-item">
                <div class="jq22-flex">
                    <div class="jq22-flex-box">
                        <h1>常用功能</h1>
                    </div>

                </div>
               <!-- <div class="jq22-palace">
                    <a href="javascript:;" class="jq22-palace-grid">
                        <div class="jq22-palace-grid-icon">
                            <img src="statics/img/nav-005.png" alt="">
                        </div>
                        <div class="jq22-palace-grid-text">
                            <h2>我的绿卡</h2>
                        </div>
                    </a>
                    <a href="javascript:;" class="jq22-palace-grid">
                        <div class="jq22-palace-grid-icon">
                            <img src="statics/img/nav-006.png" alt="">
                        </div>
                        <div class="jq22-palace-grid-text">
                            <h2>收货地址</h2>
                        </div>
                    </a>
                    <a href="javascript:;" class="jq22-palace-grid">
                        <div class="jq22-palace-grid-icon">
                            <img src="statics/img/nav-007.png" alt="">
                        </div>
                        <div class="jq22-palace-grid-text">
                            <h2>邀请有礼</h2>
                        </div>
                    </a>
                    <a href="javascript:;" class="jq22-palace-grid">
                        <div class="jq22-palace-grid-icon">
                            <img src="statics/img/nav-008.png" alt="">
                        </div>
                        <div class="jq22-palace-grid-text">
                            <h2>联系客服</h2>
                        </div>
                    </a>
                    <a href="javascript:;" class="jq22-palace-grid">
                        <div class="jq22-palace-grid-icon">
                            <img src="statics/img/nav-009.png" alt="">
                        </div>
                        <div class="jq22-palace-grid-text">
                            <h2>礼品卡</h2>
                        </div>
                    </a>
                    <a href="javascript:;" class="jq22-palace-grid">
                        <div class="jq22-palace-grid-icon">
                            <img src="statics/img/nav-010.png" alt="">
                        </div>
                        <div class="jq22-palace-grid-text">
                            <h2>扫一扫</h2>
                        </div>
                    </a>
                    <a href="javascript:;" class="jq22-palace-grid">
                        <div class="jq22-palace-grid-icon">
                            <img src="statics/img/nav-011.png" alt="">
                        </div>
                        <div class="jq22-palace-grid-text">
                            <h2>意见反馈</h2>
                        </div>
                    </a>
                    <a href="javascript:;" class="jq22-palace-grid">
                        <div class="jq22-palace-grid-icon">
                            <img src="statics/img/nav-012.png" alt="">
                        </div>
                        <div class="jq22-palace-grid-text">
                            <h2>设置</h2>
                        </div>
                    </a>
                    <a href="javascript:;" class="jq22-palace-grid">
                        <div class="jq22-palace-grid-icon">
                            <img src="statics/img/nav-013.png" alt="">
                        </div>
                        <div class="jq22-palace-grid-text">
                            <h2>企业采购</h2>
                        </div>
                    </a>
                </div>-->
            </div>
            <div style="height:50px;"></div>
        </section>
    </section>
</div>
</body>
<script src="statics/plugins/layer/layer.js"></script>
<script src="statics/libs/jquery.min.js"></script>
<script src="statics/libs/vue.min.js"></script>
<script src="statics/libs/iview.min.js"></script>
<script src="statics/libs/bootstrap.min.js"></script>
<script src="statics/plugins/slimscroll/jquery.slimscroll.min.js"></script>
<script src="statics/libs/fastclick.min.js"></script>
<script type="text/javascript">
    var vm = new Vue({
        el: '#loginBox',
        data: {
            user: {
                userId: 1,
                username: "admin",
                mobile: "1361688744166"
            },
        },
        beforeCreate: function () {
            getUser();
        },
        methods: {
            updateSysUser() {
                parent.location.href = 'updateSysUser.html';
            },
            getGoodTong(type) {
                parent.location.href = 'weipinhui.html?type=' + type;
            },
            getGoodWu(type) {
                layer.alert("暂未开放");
            }
        }
    });

    function getUser() {
        $.ajax({
            type: "GET",
            url: "sys/user/info",
            success: function (result) {
                console.log(result)
                if (result.code === 0) {
                    vm.user = result.user;
                    console.log(vm.user)
                }
            }
        });
    }
</script>

</html>
